import com.sun.jmx.remote.internal.ArrayQueue

//
//fun <T,R.R> Observable.recursive(predicate: Func1<R.R, Boolean>):Observable{
//    return this.lift()
//}

fun main(args: Array<String>) {

    val queue = ArrayQueue<User>(1)
    var nobody:User? = User("nobody")
    queue.add(nobody)
    nobody = null
    var last = queue.last()
    println(last)

}

class Psychology(name: String) : User(name) {

    @JvmField
    var user: User = User("JackSparrow")
}

open class User(var name:String)